package cn.itcast.cd.service.impl;

import java.util.List;

import cn.itcast.cd.dao.IBaseDao;
import cn.itcast.cd.dao.ISupplierDao;
import cn.itcast.cd.domain.Supplier;
import cn.itcast.cd.query.IQuery;
import cn.itcast.cd.resultPage.ResultPage;
import cn.itcast.cd.service.ISupplierService;
import cn.itcast.cd.utils.MD5;

public class SupplierServiceImpl implements ISupplierService {

	private ISupplierDao SupplierDao;
	
	public void setSupplierDao(ISupplierDao SupplierDao) {
		this.SupplierDao = SupplierDao;
	}

	@Override
	public void save(Supplier Supplier) {
		SupplierDao.save(Supplier);
	}

	@Override
	public Supplier get(Long id) {
		return (Supplier) SupplierDao.get(id);
	}

	@Override
	public ResultPage query(String hql, Object[] params, int start, int limit) {
		return SupplierDao.query(hql, params, start, limit);
	}

	@Override
	public void delete(Long id) {
		SupplierDao.delete(id);
	}

	@Override
	public void update(Supplier Supplier) {
		SupplierDao.update(Supplier);
	}

	@Override
	public ResultPage queryEntity(IQuery query) {
		
		return SupplierDao.queryEntity(query);
	}

	@Override
	public List<Supplier> queryEntity(String conditions,Object[] params){
		
		return SupplierDao.queryEntity(conditions, params);
	}
	
	
	

}
